import { readFileSync } from 'fs-extra';
import { join } from 'path';
import { App } from 'vue';

const useComp = (app: App) => {
    app.component('comp', {
        template: readFileSync(join(__dirname, '../../static/template/vue/comp.html'), 'utf-8'),
        data() {
            return {
                text: 'Err',
            };
        }, 
        methods: {
            test() {
                this.text = 'Ok';
            },
        },
    })
}

export { useComp };